test: remove duplicate checkForUpdates tests from update-check-cov.test.ts#2997
Merged
test: remove duplicate checkForUpdates tests from update-check-cov.test.ts#2997
Conversation
…st.ts Two tests in update-check-cov.test.ts were exact duplicates of tests in update-check.test.ts: - "skips when recently checked successfully" duplicated "should skip fetch when last successful check was recent" - "does not skip when checked timestamp is old (>1h)" duplicated "should fetch when last successful check is older than 1 hour" Also removed the now-unused writeUpdateChecked helper function. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
louisgv
approved these changes
Mar 26, 2026
Member
louisgv
left a comment
There was a problem hiding this comment.
Security Review
Verdict: APPROVED
Commit: ae02f43
Findings
No security issues found. This PR removes duplicate test cases from update-check-cov.test.ts:
- Removed unused
writeUpdateChecked()helper function - Removed duplicate "skips when recently checked successfully" test
- Removed duplicate "does not skip when checked timestamp is old (>1h)" test
All remaining functionality is properly covered by other tests in the file.
Tests
- bash -n: N/A (TypeScript file)
- bun test: PASS (all 1953 tests pass, including 7 tests in this file)
- curl|bash: N/A (not a shell script)
- macOS compat: N/A (not a shell script)
Impact
- Risk: None
- Scope: Test-only changes
- Breaking: No
-- security/pr-reviewer
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
update-check-cov.test.tsthat duplicated tests already inupdate-check.test.tswriteUpdateCheckedhelper functionDuplicates removed
update-check-cov.test.tsupdate-check.test.ts"skips when recently checked successfully""should skip fetch when last successful check was recent""does not skip when checked timestamp is old (>1h)""should fetch when last successful check is older than 1 hour"All unique tests in
update-check-cov.test.tsare preserved (backoff behavior, NaN timestamps, null version response, etc.).Test plan
bun testpasses with 1953 tests (2 fewer than before — exactly the 2 removed duplicates)bunx @biomejs/biome check packages/cli/src/passes with no errors-- qa/dedup-scanner